package studentinformationmanagementsystem.entity;

import java.io.Serializable;
import java.sql.Date;
import java.util.Objects;

/**
 * @author 苗庆
 * @version 1.0
 * 学生实体类
 */
public class Student implements Serializable {
    private static final long serialVersionUID = 1L;

    //id
    private Integer studid;
    //学号即账号
    private String studentid;
    //姓名
    private String studentname;
    //身份证号
    private String idnumber;
    //性别
    private String sex;
    //出生日期
    private Date birthdate;
    //民族
    private String nation;
    //政治面貌
    private String politicsstatus;
    //个人照片
    private String photograph;
    //联系电话
    private String phone;
    //邮箱
    private String mailbox;
    //班级
    private String classandgrade;
    //专业
    private String major;
    //院系
    private String department;

    //家庭住址
    private String homeaddress;

    //紧急联系人
    private String emergencycontact;

    //紧急联系人电话
    private String emergencycontactphone;

    //籍贯
    private String nativeplace;

    //密码
    private String password;

    //入学时间
    private Date AdmissionDate;

    public Student(Integer studid, String studentid, String studentname, String idnumber, String sex, Date birthdate, String nation, String politicsstatus, String photograph, String phone, String mailbox, String classandgrade, String major, String department, String homeaddress, String emergencycontact, String emergencycontactphone, String nativeplace, String password, Date admissionDate) {
        this.studid = studid;
        this.studentid = studentid;
        this.studentname = studentname;
        this.idnumber = idnumber;
        this.sex = sex;
        this.birthdate = birthdate;
        this.nation = nation;
        this.politicsstatus = politicsstatus;
        this.photograph = photograph;
        this.phone = phone;
        this.mailbox = mailbox;
        this.classandgrade = classandgrade;
        this.major = major;
        this.department = department;
        this.homeaddress = homeaddress;
        this.emergencycontact = emergencycontact;
        this.emergencycontactphone = emergencycontactphone;
        this.nativeplace = nativeplace;
        this.password = password;
        AdmissionDate = admissionDate;
    }

    public Student() {

    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Student student = (Student) o;
        return studid.equals(student.studid);
    }

    @Override
    public int hashCode() {
        return Objects.hash(studid);
    }

    @Override
    public String toString() {
        return "Student{" +
                "studid=" + studid +
                ", studentid='" + studentid + '\'' +
                ", studentname='" + studentname + '\'' +
                ", idnumber='" + idnumber + '\'' +
                ", sex='" + sex + '\'' +
                ", birthdate=" + birthdate +
                ", nation='" + nation + '\'' +
                ", politicsstatus='" + politicsstatus + '\'' +
                ", photograph='" + photograph + '\'' +
                ", phone='" + phone + '\'' +
                ", mailbox='" + mailbox + '\'' +
                ", classandgrade='" + classandgrade + '\'' +
                ", major='" + major + '\'' +
                ", department='" + department + '\'' +
                ", homeaddress='" + homeaddress + '\'' +
                ", emergencycontact='" + emergencycontact + '\'' +
                ", emergencycontactphone='" + emergencycontactphone + '\'' +
                ", nativeplace='" + nativeplace + '\'' +
                ", password='" + password + '\'' +
                ", AdmissionDate=" + AdmissionDate +
                '}';
    }

    public static long getSerialVersionUID() {
        return serialVersionUID;
    }

    public Integer getStudid() {
        return studid;
    }

    public void setStudid(Integer studid) {
        this.studid = studid;
    }

    public String getStudentid() {
        return studentid;
    }

    public void setStudentid(String studentid) {
        this.studentid = studentid;
    }

    public String getStudentname() {
        return studentname;
    }

    public void setStudentname(String studentname) {
        this.studentname = studentname;
    }

    public String getIdnumber() {
        return idnumber;
    }

    public void setIdnumber(String idnumber) {
        this.idnumber = idnumber;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }

    public Date getBirthdate() {
        return birthdate;
    }

    public void setBirthdate(Date birthdate) {
        this.birthdate = birthdate;
    }

    public String getNation() {
        return nation;
    }

    public void setNation(String nation) {
        this.nation = nation;
    }

    public String getPoliticsstatus() {
        return politicsstatus;
    }

    public void setPoliticsstatus(String politicsstatus) {
        this.politicsstatus = politicsstatus;
    }

    public String getPhotograph() {
        return photograph;
    }

    public void setPhotograph(String photograph) {
        this.photograph = photograph;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getMailbox() {
        return mailbox;
    }

    public void setMailbox(String mailbox) {
        this.mailbox = mailbox;
    }

    public String getClassandgrade() {
        return classandgrade;
    }

    public void setClassandgrade(String classandgrade) {
        this.classandgrade = classandgrade;
    }

    public String getMajor() {
        return major;
    }

    public void setMajor(String major) {
        this.major = major;
    }

    public String getDepartment() {
        return department;
    }

    public void setDepartment(String department) {
        this.department = department;
    }

    public String getHomeaddress() {
        return homeaddress;
    }

    public void setHomeaddress(String homeaddress) {
        this.homeaddress = homeaddress;
    }

    public String getEmergencycontact() {
        return emergencycontact;
    }

    public void setEmergencycontact(String emergencycontact) {
        this.emergencycontact = emergencycontact;
    }

    public String getEmergencycontactphone() {
        return emergencycontactphone;
    }

    public void setEmergencycontactphone(String emergencycontactphone) {
        this.emergencycontactphone = emergencycontactphone;
    }

    public String getNativeplace() {
        return nativeplace;
    }

    public void setNativeplace(String nativeplace) {
        this.nativeplace = nativeplace;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Date getAdmissionDate() {
        return AdmissionDate;
    }

    public void setAdmissionDate(Date admissionDate) {
        AdmissionDate = admissionDate;
    }
}
